<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        function numberToChinese(num) {
            switch (num) {
                case "1": return "一";
                case "2": return "二";
                case "3": return "三";
                case "4": return "四";
                default: return num; // 可以选择处理未知数字的情况
            }
        }

        let arr = ["1", "2", "3", "4"];
        let chineseArr = arr.map(numberToChinese);

        console.log(chineseArr); // ["一", "二", "三", "四"]
    </script>
</body>

</html>